
#ifndef _RADIX_ENGINE_RENDER_H_
#define _RADIX_ENGINE_RENDER_H_

#include <Engine/Component.h>

_BeginNamespace(Radix)
/*
=================================================================
== RenderResource Enums
=================================================================
*/
enum RenderResourceCpuAccess
{
	eRenderResourceCpuAccess_Automatic,
	eRenderResourceCpuAccess_ReadOnly,
	eRenderResourceCpuAccess_WriteOnly,
	eRenderResourceCpuAccess_ReadWrite
};

enum RenderResourceUsage
{
	eRenderResourceUsage_Default,
	eRenderResourceUsage_Immutable,
	eRenderResourceUsage_Dynamic,
	eRenderResourceUsage_Staging
};
/*
=================================================================
== VertexElement
=================================================================
*/
enum VertexElement
{
	eVertexElement_Position,
	eVertexElement_Color,
	eVertexElement_Normal,
	eVertexElement_TexCoord2,
	eVertexElement_TexCoord3,
	eVertexElement_TexCoord4
};

/*
=================================================================
== IGeometry
=================================================================
*/
class IGeometry :public Interface
{
public:

};
/*
=================================================================
== IShader
=================================================================
*/
class IShader :public Interface
{};
/*
=================================================================
== IMaterial
=================================================================
*/
class IMaterial :public Interface
{};
/*
=================================================================
== IRenderObject
=================================================================
*/
class IRenderObject :public Interface
{
public:
	virtual const Matrix4x4& transform() = 0;
	virtual void transform(const Matrix4x4& t) = 0;
	virtual const IGeometry& geometry() = 0;
	virtual void geometry(const IGeometry& g) = 0;
	virtual const IMaterial& material() = 0;
	virtual void material(const IMaterial& m) = 0;
};
/*
=================================================================
== IRenderPipeline
=================================================================
*/
class IRenderPipeline :public Interface
{
public:

};
/*
=================================================================
== IRenderSystem
=================================================================
*/
class IRenderSystem :public IComponent
{
public:
	virtual IGeometry* createGeometry(const Mesh& mesh) = 0;
	virtual void dispatchObject(const IRenderObject& object) = 0;
	virtual void renderFrame(real elapsed) = 0;
};

_EndNamespace(Radix)

#endif//_RADIX_ENGINE_RENDER_H_
